﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="ViewContact.ascx.cs" Inherits="controls_admin_ViewContact" %>
<!-- table -->
<div class="box">
    <!-- box / title -->
    <div class="title">
        <h5>
            Danh Sách</h5>
        <div class="search">
            <div class="input">
            </div>
            <div class="button">
            </div>
        </div>
    </div>
    <div id="divMessage" runat="server">
    </div>
    <div id="divResult" class="result" runat="server">
    </div>
    <!-- end box / title -->
    <div class="table">
        <table>
            <thead>
                <tr>
                    <th class="left">
                        Tiêu Đề
                    </th>
                    <th>
                        Người gửi
                    </th>
                    <th>
                        Email
                    </th>
                    <th>
                        Ngày gửi
                    </th>
                    <th class="last">
                    </th>
                </tr>
            </thead>
            <tbody>
                <asp:Repeater ID="rptContact" runat="server">
                    <ItemTemplate>
                        <tr>
                            <td>
                                <%#Eval("CONTACT_TITLE")%>
                            </td>
                            <td>
                                <%#Eval("SENDER_NAME")%>
                            </td>
                            <td>
                                <%#Eval("SENDER_EMAIL")%>
                            </td>
                            <td class="date">
                                <%#Eval("CREATED_DATE")%>
                            </td>
                            <td class="last">
                                <a href='default.aspx?module=contactdetails&id=<%#Eval("CONTACT_ID")%>'>Chi tiết</a>
                            </td>
                        </tr>
                    </ItemTemplate>
                </asp:Repeater>
            </tbody>
        </table>
        <div class="pagination pagination-left">
            <div class="pagerContainer" id="pagerContainer" runat="server">
            </div>
        </div>
        <div style="text-align: center; margin: 10px">
            <%if (Session["url"] != null)
              {
                  if (!Session["url"].ToString().Equals(Request.Url.ToString()))
                  {
                      Session["urlref"] = Session["url"].ToString();
                      Session["url"] = Request.Url.ToString();
                  }
            %>
            <a href='<%=Session["urlref"].ToString()%>' title="Trang trước">
                <%}
              else
              {
                  Session.Add("url", Request.Url.ToString());
                  Session.Add("urlref", Request.Url.ToString()); %>
                <a href="default.aspx" title="Trang trước">
                    <%} %>
                    <img src="../resources/images/icons/16x16/arrow-return.png" alt="Trang trước" /></a>
                &nbsp;&nbsp; <a href="default.aspx" title="Trang chủ">
                    <img src="../resources/images/icons/16x16/home.png" alt="Trang chủ" /></a>
        </div>
    </div>
</div>
<!-- end table -->
